﻿using System;
using System.Linq;
using System.Threading;
using System.Web.Mvc;

namespace JQueryDemo.MVC.Controllers
{
   public class HomeController : Controller
   {
      public ActionResult Index()
      {
         return View();
      }

      public ActionResult Prep()
      {
         return View();
      }

      public ActionResult FinalPrep()
      {
         return View();
      }

      public ActionResult GetDogYearChoices()
      {
         Thread.Sleep(2000);

         var data = Enumerable
            .Range(1, 100)
            .Select(x => new {Age = x, AgeInDogYears = x * 7})
            .ToArray();

         return Json(data);
      }
   }
}